import routes from './router'
import './icon.js';
import '../base-theme/root.scss'
import '../assets/style/mixins.scss'
import type { farmeWorkType, menu } from '../interface/utils'
import { RouteRecordRaw } from 'vue-router'
import components from './components.ts';
import resizable from './resizable.ts'
// 1.处理登陆状态
// 2.鉴权-路由表
// 3.路由信息
// 4.挂载farmework
const farmeWork: farmeWorkType = {
  isLogin: true,
  userInfo: {
    userId: ''
  },
  menu: {} as menu,
  router: routes as Array<RouteRecordRaw>,
  components,
  resizable
};

function applicationInit(): promises {
  return new Promise((resolve, reject) => {
    resolve(farmeWork)
  })
}

export default applicationInit;
